package com.share.bean.template;

import java.util.Date;
import java.util.Set;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToMany;
import javax.persistence.Table;

/**
 * <p>Title：模板分类</p>
 * <p>Description：</p>
 * @Author：杨浩泉
 * @Date：2010-4-17
 */
@Entity
@Table(name="share_templateItem")
public class TemplateItem {
	
	private int tempItemId ;
	
	/** 模板分类名称 */
	private String tempItemName ;

	/** 模板分类描述 */
	private String tempItemDesc ;

	private Date addTime ;
	
	private Set<Template> template ;
	
	public Date getAddTime() {
		return addTime;
	}
	
	public String getTempItemDesc() {
		return tempItemDesc;
	}
	
	@Id
	@GeneratedValue
	public int getTempItemId() {
		return tempItemId;
	}

	public String getTempItemName() {
		return tempItemName;
	}

	@OneToMany(mappedBy="templateItem")
	@JoinColumn(name="template_id")
	public Set<Template> getTemplate() {
		return template;
	}

	public void setAddTime(Date addTime) {
		this.addTime = addTime;
	}

	public void setTempItemDesc(String tempItemDesc) {
		this.tempItemDesc = tempItemDesc;
	}

	public void setTempItemId(int tempItemId) {
		this.tempItemId = tempItemId;
	}

	public void setTempItemName(String tempItemName) {
		this.tempItemName = tempItemName;
	}

	public void setTemplate(Set<Template> template) {
		this.template = template;
	}
}
